/* 添加暗夜模式样式 */
body.dark-mode {
    background-color: #121212;
    color: #e0e0e0;
}

.dark-mode .content {
    background-color: #1e1e1e;
    color: #e0e0e0;
}

.dark-mode .navbar {
    background-color: #1e1e1e;
    border-bottom: 1px solid #333;
}

.dark-mode .navbar a {
    color: #e0e0e0;
}

.dark-mode .navbar a:hover {
    background-color: #333;
    color: #fff;
}

.dark-mode #message-form {
    background-color: #1e1e1e;
    border-top: 1px solid #333;
}

.dark-mode #message-form textarea {
    background-color: #333;
    color: #e0e0e0;
    border: 1px solid #444;
}

.dark-mode #message-form input[type="submit"] {
    background-color: #007BFF;
    color: #fff;
}

.dark-mode #message-form input[type="submit"]:hover {
    background-color: #0056b3;
}

/* 修改导航栏样式 */
.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 20px;
    background-color: #007BFF;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.nav-left, .nav-right {
    display: flex;
    align-items: center;
}

.navbar a {
    color: #fff;
    text-decoration: none;
    padding: 10px 15px;
    margin: 0 5px;
    border-radius: 5px;
    transition: background-color 0.3s, color 0.3s;
}

.navbar a:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.navbar .avatar img {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #fff;
}

#theme-toggle {
    background-color: #fff;
    color: #007BFF;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    cursor: pointer;
    transition: background-color 0.3s, color 0.3s;
}

#theme-toggle:hover {
    background-color: #f0f0f0;
}

/* 暗夜模式下的导航栏样式 */
.dark-mode .navbar {
    background-color: #1e1e1e;
    border-bottom: 1px solid #333;
}

.dark-mode .navbar a {
    color: #e0e0e0;
}

.dark-mode .navbar a:hover {
    background-color: #333;
    color: #fff;
}

.dark-mode #theme-toggle {
    background-color: #333;
    color: #e0e0e0;
}

.dark-mode #theme-toggle:hover {
    background-color: #444;
}

/* 添加切换按钮样式 */
#theme-toggle {
    background-color: #007BFF;
    color: #fff;
    border: none;
    border-radius: 5px;
    padding: 10px 20px;
    cursor: pointer;
    transition: background-color 0.3s;
}

#theme-toggle:hover {
    background-color: #0056b3;
}